interface IconBackgroundImage {
  large: string;
  medium: string;
  small: string;
}

interface TimerStyle {
  fontColor: string;
  bgType: string;
  bgColor: string;
  bgImageColor: string;
  bgImage: IconBackgroundImage;
  bgMask: number;
}

interface WidgetData {
  name: string;
  time: number;
  dateType: string;
  timerStyle: TimerStyle;
}

export type WIDGET_TYPE = "sysWidget";
export type SITE_TYPE = "site";
export enum TYPE {
  WIDGET = "widget",
  SITE = "site",
  FOLDER = "folder",
  INNER_SITE = "inner-site",
  TABLE='table',
  COMPONENT='component',
  WIDGET_A = 'widget_A'
}

export type IconChild = {
  type: TYPE;
  name: string;
  widgetSize?: string;
  widgetName?: string;
  origin: string;
  widgetData?: WidgetData;
  id: string;
  updateTime: number;
  target?: string;
  bgType?: string;
  bgColor?: string;
  bgImage?: string;
  bgText?: string;
  total?: number;
  lasttime?: number;
};

export interface IconCategory {
  id?: string;
  iconClass: string;
  name: string;
  updateTime?: number;
  children: IconChild[];
}

interface RootObject {
  icons: IconCategory[];
  dockIdList: string[];
  aiCateUserDecided: boolean;
  aiCateOriginIds: string[];
  aiCateId: string;
  aiCateNameChanged: boolean;
  updateCloudTime: number;
}
